//
//  Person.h
//  Lesson -02
//
//  Created by dllo on 16/2/25.
//  Copyright © 2016年 Apon. All rights reserved.
//

#import <Foundation/Foundation.h>

@interface Person : NSObject

//实例变量
{
@public
    NSString *_name;
    @protected
    NSString *_sex;
    @private
    NSInteger _age;

}

//方法


//自定义初始化方法
-(instancetype)initWithName:(NSString *)name;
-(instancetype)initWithName:(NSString *)name sex:(NSString *)sex age:(NSInteger)age;

-(void)sayHi;


-(void)name:(NSString *)name Sex:(NSString *)sex Age:(NSInteger)age;

//setter ,getter方法
//需求:通过一个方法,对_name实例变量赋值;
//需求:通过一个方法,取出_name实例变量值;
-(void)setName:(NSString *)name;
-(NSString *)name;


//构造器
+(instancetype)person;

+(instancetype)personWithName:(NSString *)name sex:(NSString *)sex age:(NSInteger)age;









@end
